Control system with wireless messages containing message sequence information

ABSTRACT

A control system uses a wireless mesh network to provide communication between a host computer and field devices. The host and the field devices communicate with one another using wireless messages containing requests and responses that are routed through the wireless mesh network. The wireless messages include sequence information that allow the receiving device to identify and reject messages that are received out of order.

CROSS-REFERENCE TO RELATED APPLICATIONS

This application claims priority from a application entitled LOW POWERWIRELESS NETWORKS OF FIELD DEVICES, Ser. No. 60/758,167, filed on Jan.11, 2006, which is incorporated by reference.

Reference is also made to co-pending applications filed on even datewith this application: CONTROL SYSTEM WITH WIRELESS ADDRESS DOMAIN TOFIELD DEVICE ADDRESS DOMAIN TRANSLATION, Ser. No. 11/652,400; CONTROLSYSTEM WITH PREDICTIVE FIELD DEVICE RESPONSE TIME OVER A WIRELESSNETWORK, Ser. No. 11/652,392; VISUAL MAPPING OF FIELD DEVICE MESSAGEROUTES IN A WIRELESS MESH NETWORK, Ser. No. 11/652,398; SELECTIVEACTIVATION OF FIELD DEVICES IN LOW POWER WIRELESS MESH NETWORKS, Ser.No. 11/652,395; CONTROL OF LOW POWER WIRELESS NETWORKS FOR POWERCONSERVATION, Ser. No. 11/652,399; and CONTROL OF FIELD DEVICE ON LOWPOWER WIRELESS NETWORKS, Ser No. 11/652,393, which are incorporated byreference.

BACKGROUND OF THE INVENTION

The present invention relates to wireless networks. In particular, theinvention relates to a wireless mesh network in which process controlmessages are communicated between a host and field devices at nodes ofthe wireless mesh network.

In many industrial settings, control systems are used to monitor andcontrol inventories, processes, and the like. Often, such controlsystems have a centralized control room with a host computer thatcommunicates with field devices that are separated or geographicallyremoved from the control room.

Generally, each field device includes a transducer, which may generatean output signal based on a physical input or generate a physical outputbased on an input signal. Types of transducers used in field devicesinclude various analytical equipment, pressure sensors, thermistors,thermocouples, strain gauges, flow sensors, positioners, actuators,solenoids, indicators, and the like.

Traditionally, analog field devices have been connected to the processsubsystem and the control room by two-wire twisted-pair current loops,with each device connected to the control room by a single two-wiretwisted pair loop. Typically, a voltage differential is maintainedbetween the two wires of approximately 20 to 25 volts, and a currentbetween 4 and 20 milliamps (mA) runs through the loop. An analog fielddevice transmits a signal to the control room by modulating the currentrunning through the current loop to a current proportional to the sensedprocess variable. An analog field device that performs an action underthe control of the control room is controlled by the magnitude of thecurrent through the loop, which is modulated by the ports of the processsubsystem under the control of the controller.

While historically field devices were capable of performing only onefunction, more recently hybrid systems that superimpose digital data onthe current loop have been used in distributed control systems. TheHighway Addressable Remote Transducer (HART) superimposes a digitalcarrier signal on the current loop signal. The digital carrier signalcan be used to send secondary and diagnostic information. Examples ofinformation provided over the carrier signal include secondary processvariables, diagnostic information (such as sensor diagnostics, devicediagnostics, wiring diagnostics, process diagnostics, and the like),operating temperatures, sensor temperature, calibration data, device IDnumbers, configuration information, and so on. Accordingly, a singlefield device may have a variety of input and output variables and mayimplement a variety of functions.

Another approach uses a digital communication bus to connect multiplefield devices to the host in the control room. Examples of digitalcommunication protocols used with field devices connected to a digitalbus include Foundation Fieldbus, Profibus, Modbus, and DeviceNet. Twoway digital communication of messages between a host computer andmultiple field devices can be provided over the same two-wire path thatsupplies power to the field devices.

Typically, remote applications have been added to a control system byrunning very long homerun cables from the control room to the remoteapplication. If the remote application is, for example, a half of a mileaway, the costs involved in running such a long cable can be high. Ifmultiple homerun cables have to be run to the remote application, thecosts become even higher. Wireless communication offers a desirablealternative, and wireless mesh networks have been proposed for use inindustrial process control systems. However, to minimize costs, it isalso desirable to maintain existing control systems and communicationprotocols, to reduce the costs associated with changing existing systemsto accommodate the wireless communication.

In wireless mesh network systems designed for low powersensor/actuator-based applications, many devices in the network must bepowered by long-life batteries or by low power energy-scavenging powersources. Power outlets, such as 120 VAC utilities, are typically notlocated nearby or may not be allowed into the hazardous areas where theinstrumentation (sensors) and actuators must be located withoutincurring great installation expense. The need for low installation costdrives the need for battery-powered devices communicating as part of awireless mesh network. Effective utilization of a limited power source,such as a primary cell battery which cannot be recharged, is vital for awell functioning wireless device. Batteries are expected to last morethan 5 years and preferably as long as the life of the product.

In a true wireless mesh network, each node must be capable of routingmessages for itself as well as other nodes in the mesh network. Theconcept of messages hopping from node to node through the network isbeneficial because lower power RF radios can be used, and yet the meshnetwork can span a significant physical area delivering messages fromone end to the other. High power radios are not needed in a meshnetwork, in contrast a point-to-point system which employs remote nodestalking directly to a centralized base-station.

A mesh network protocol allows for the formation of alternate paths formessaging between nodes and between nodes and a data collector, or abridge or gateway to some higher level higher-speed data bus. Havingalternate, redundant paths for wireless messages enhances datareliability by ensuring there is at least one alternate path formessages to flow even if another path gets blocked or degrades due toenvironmental influences or due to interference.

Some mesh network protocols are deterministically routed such that everynode has an assigned parent and at least one alternate parent. In thehierarchy of the mesh network, much as in a human family, parents havechildren, children have grandchildren, and so on. Each node relays themessages for their descendants through the network to some finaldestination such as a gateway. The parenting nodes may bebattery-powered or limited-energy powered devices. The more descendantsa node has, the more traffic it must route, which in turn directlyincreases its own power consumption and diminishes its battery life.

In order to save power, some protocols limit the amount of traffic anynode can handle during any period of time by only turning on the radiosof the nodes for limited amounts of time to listen for messages. Thus,to reduce average power, the protocol may allow duty-cycling of theradios between On and Off states. Some protocols use a global duty cycleto save power such that the entire network is On and Off at the sametime. Other protocols (e.g. TDMA-based) use a local duty cycle whereonly the communicating pair of nodes that are linked together arescheduled to turn On and Off in a synchronized fashion at predeterminedtimes. Typically, the link is pre-determined by assigning the pair ofnodes a specific time slot for communications, an RF frequency channelto be used by the radios, who is to be receiving (Rx), and who is to betransmitting (Tx) at that moment in time.

Some protocols employ the concept of assigning links to nodes on aregular repetitive schedule and thereby enable regular delivery ofupdates and messages from devices in the network. Some advancedTMDA-based protocols may employ the concept of multiple activeschedules, these multiple schedules running all at the same time or withcertain schedules activated/deactivated by a global network controlleras the need arises. For example, slow active schedules link nodessending messages with longer periods of time (long cycle time) betweenmessages to achieve low power consumption. Fast active schedules linknodes sending messages more rapidly for better throughput and lowerlatency, but result in higher power consumption in the nodes. Withprotocols that allow multiple active schedules, some schedules could beoptimized for upstream traffic, others for downstream traffic and yetothers for network management functions such as device joining andconfiguration. Globally activating/deactivating various schedulesthroughout the entire network in order to meet different needs atdifferent times provides a modicum of flexibility for achievingadvantageous trade-offs between power consumption and low latency, butapplies the same schedule to all nodes and thus does not provide localoptimization.

In a synchronized system, nodes will have to wait to transmit untiltheir next predetermined On time before they can pass messages. Waitingincreases latency, which can be very detrimental in many applications ifnot bounded and managed properly. If the pair of nodes that are linkedtogether are not synchronized properly, they will not succeed in passingmessages because the radios will be On at the wrong time or in the wrongmode (Rx or Tx) at the wrong time. If the only active schedule has along cycle time, the time between scheduled links will be long andlatency will suffer. If a fast schedule is activated, the time betweenscheduled links will be short but battery life will be measurablyreduced over time.

Some protocols allow running a slow schedule in the background andglobally activating/deactivating an additional fast schedule. Since ittakes time to globally activate a fast schedule throughout the entirenetwork and get confirmation back from all nodes that they have heardthe global command, the network or sub-network remains in the lessresponsive mode during the transition time. Furthermore, with a globallyactivated fast schedule, power is wasted in all the parenting nodes inthe network, even those whose descendants will not benefit from the fastschedule. These unappreciative parent nodes must listen more often onthe global fast active schedule (i.e. turn their radios On to Rx moreoften); even though their descendants have nothing extra to send that aregular active schedule would not suffice in that portion of thenetwork.

Some protocols may limit the number of descendants a node can have,thereby reducing the load the node must support. Other protocols mayemploy a combination of all of these measures to reduce average powerconsumption. All of these power-saving measures have the effect ofreducing the availability of the nodes in the network to do the work ofpassing messages, thereby increasing the latency of messages deliveredthrough the network. Duty-cycling the radio increases latency. Hoppingmessages from node to node increases latency. Increasing hop depth (hopcount) by limiting the number of descendants increases latency. Runninga slow active schedule (long cycle period) increases latency. Evenglobally activating a fast active schedule takes time. It is likely thatthe value of information diminishes with time, so the longer thelatency, the less valuable the information may be.

BRIEF SUMMARY OF THE INVENTION

A distributed control system includes a wireless network to providecommunication between a host and field devices. The host and the fielddevices communicate with messages that are routed through a wirelessmesh network. The wireless messages routed between the host and thefield devices over the network include sequence information, such as amessage ID number, so that the receiving device can identify messagesthat are received out of order.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a diagram illustrating a control system in which a wirelessmesh network routes wireless messages between a host and field devices.

FIG. 2 is a block diagram of a portion of the control system of FIG. 1,including a host computer, a gateway node, and a wireless node with afield device.

FIG. 3 is a diagram illustrating the format of wireless messagestransmitted by the wireless network.

FIG. 4 shows the format of a control message from a host to a fielddevice based upon a control system protocol.

FIG. 5 shows one embodiment of the control message as modified to formthe payload of the wireless message shown in FIG. 3.

FIG. 6 shows another embodiment of the control message as modified witha trailer to form the payload of the wireless message shown in FIG. 3.

DETAILED DESCRIPTION

FIG. 1 shows control system 10, which includes host computer 12,highspeed network 14, and wireless mesh network 16, which includesgateway 18 and wireless nodes 20, 22, 24, 26, 28, and 30. Gateway 18interfaces mesh network 16 with host computer 12 over highspeed network14. Messages may be transmitted from host computer 12 to gateway 18 overnetwork 14, and are then transmitted to a selected node of mesh network16 over one of several different paths. Similarly, messages fromindividual nodes of mesh network 16 are routed through mesh network 16from node-to-node over one of several paths until they arrive at gateway18 and are then transmitted to host 12 over highspeed network 14.

Control system 10 can make use of field devices that have been designedfor and used in wired distributed control systems, as well as fielddevices that are specially designed as wireless transmitters for use inwireless mesh networks. Nodes 20, 22, 24, 26, 28, and 30 show examplesof wireless nodes that include conventional field devices.

Wireless node 20 includes radio 32, wireless device router (WDR) 34, andfield devices FD1 and FD2. Node 20 is an example of a node having oneunique wireless address and two unique field device addresses.

Nodes 22, 24, 26, and 28 are each examples showing nodes having oneunique wireless address and one unique field device address. Node 22includes radio 36, WDR 38, and field device FD3. Similarly, field device24 includes radio 40, WDR 42, and field device FD4; node 26 includesradio 44, WDR 46, and field device FD5, and node 28 includes radio 48,WDR 50, and field device FD6.

Node 30 has one unique wireless address and three unique field deviceaddresses. It includes radio 52, WDR 54, and field devices FD7, FD8, andFD9.

Wireless network 16 is preferably a low power network in which many ofthe nodes are powered by long life batteries or low power energyscavenging power sources. Communication over wireless network 16 may beprovided according to a mesh network configuration, in which messagesare transmitted from node-to-node through network 16. This allows theuse of lower power RF radios, while allowing the network 16 to span asignificant physical area to deliver messages from one end of thenetwork to the other.

In a wired control system, interaction between the host computer and thefield devices occurs using well known control messages according to acontrol message protocol such as HART, Foundation Fieldbus, Profibus, orthe like. Field devices capable of use in wired control systems (such asfield devices FD1-FD9 shown in FIG. 1) make use of control messagesaccording to one of the known control message protocols. Wireless nodes20-30, which are part of wireless network 16, cannot directly exchangethese well known control messages with host computer 12 because thewireless communication over network 16 occurs according to a wirelessprotocol that is general purpose in nature.

Rather than require host computer 12 and field devices FD1-FD9 tocommunicate using wireless protocol, a method can be provided to allowsending and receiving well known field device control messages betweenhost computer 12 and field devices FD1-FD9 over wireless network 16. Thewell known field device control messages are embedded into the generalpurpose wireless protocol so that the control messages can be exchangedbetween host computer 12 and field devices FD1-FD9 to achieve control ofan interaction with field devices FD1-FD9. As a result, wireless network16 and its wireless communication protocol is essentially transparent tohost computer 12 and field devices FD1-FD9. In the followingdescription, the HART protocol will be used as an example of a knowncontrol message protocol, although the invention is applicable to othercontrol message protocols (e.g. Foundation Fieldbus, Profibus, etc.) aswell.

A similar issue relates to the addresses used by host computer 12 todirect messages to field devices FD1-FD9. In wired systems, the hostcomputer addresses each field device with a unique field device address.The address is defined as part of the particular communication protocolbeing used, and typically forms a part of control messages sent by thehost computer to the field devices.

When a wireless network, such as network 16 shown in FIG. 1 is used toroute messages from the host computer to field devices, the field deviceaddresses used by the host computer are not compatible with the wirelessaddresses used by the communication protocol of the wireless network. Inaddition, there can be multiple field devices associated with a singlewireless node, as illustrated by wireless nodes 20 and 30 in FIG. 1.Wireless node 20 includes two field devices, FD1 and FD2, while wirelessnode 30 is associated with three field devices, FD7-FD9.

One way to deal with addresses is to require host computer 12 to usewireless addresses rather than field device addresses. This approach,however, requires host computer 12 to be programmed differentlydepending upon whether it is communicating over wired communicationlinks with field devices, or whether it is communicating at least inpart over a wireless network. In addition, there remains the issue ofmultiple field devices, which will typically have different purposes,and which need to be addressed individually.

An alternative approach uses gateway 18 to translate field deviceaddresses provided by host computer 16 into corresponding wirelessaddresses. A wireless message is sent to the wireless address, and alsoincludes a field device address so that the node receiving the messagecan direct the message to the appropriate field device. By translatingfield device addressees to corresponding wireless addresses, hostcomputer 12 can function in its native field address domain wheninteracting with field devices. The presence of wireless network 16 istransparent to host computer 12 and field devices FD1-FD9.

Still another issue caused by the use of wireless network 16 tocommunicate between host computer 12 and field devices FD1-FD9 is theunavailability of field devices because of power conservation. In awired control system, the host computer interacts with field devices asif they were available on demand. The assumption is that the fielddevices are always powered up and available.

In a low power wireless network, this is not the case. To conservepower, field devices in a low power wireless network are unavailable, orasleep, most of the time. Periodically, the wireless network goes into anon-sleep state during which messages can be communicated to and fromthe field devices. After a period of time, the wireless network againgoes into a low power sleep state.

If the host computer attempts to communicate during a period when thewireless network is in a sleep state, or when a particular field deviceis in a low power sleep state, the failure of the field device torespond immediately can be interpreted by the host computer as acommunication failure. The host computer does not determine theparticular route that messages take through the wireless network, anddoes not control the power up and power down cycles for wirelesscommunication. As a result, the host computer can interpret a lack ofresponse of field devices as a device failure, when the lack of responseis an inherent result of the way that communication takes place within alow power wireless network.

In order to make the presence of wireless network 16 transparent to hostcomputer 12, gateway 18 decouples transmission of field device messagesbetween host computer 12 and wireless network 16. Gateway 18 determinesthe current state of wireless network 16 and tracks its power cycles. Inaddition, it maintains information on the response times required for afield device to be turned on and then be ready to provide a responsemessage to a control message from host computer 12.

When a message is provided by host computer 12 to gateway 18, adetermination of an expected response time is made based upon the fielddevice address. That expected response time is provided to host computer12, so that host computer 12 will not treat the absence of a responsemessage prior to the expected response time elapsing as a communicationfailure. As a result, host computer 12 is allowed to treat field devicesFD1-FD9 as if they were available on demand, when in fact wirelessnetwork 16 and field devices FD1-FD9 are not available on demand.

FIG. 2 shows a block diagram of a portion of the control system 10 shownin FIG. 1. FIG. 2, host computer 12, highspeed network 14, gateway 18,and wireless node 22 are shown.

In FIG. 2, host computer 12 is a distributed control system host runningapplication programs to facilitate sending messages to field devicesFD1-FD9, and receiving and analyzing data contained in messages fromfield devices FD1-FD9. Host computer 12 may use, for example, AMS (tm)Device Manager as an application program to allow users to monitor andinteract with field devices FD1-FD9.

Host computer 12 communicates with gateway 18 using messages inextendable markup language (XML) format. Control messages intended forfield devices FD1-FD9 are presented according to the HART protocol, andare communicated to gateway 18 in XML format.

In the embodiment shown in FIG. 2, gateway 18 includes gateway interface60, mesh manager 62, and radio 64. Gateway interface 60 receives the XMLdocument from host computer 12, extracts the HART control message, andmodifies the control message into a format to be embedded in a wirelessmessage that will be transmitted over wireless network 16.

Mesh manager 62 forms the wireless message with the HART control messageembedded, and with the wireless address of the node corresponding to thefield device to which the HART message is directed. Mesh manager 62 maybe maintaining, for example, a lookup table that correlates each fielddevice address with the wireless address of the node at which the fielddevice corresponding to that field device address is located. In thisexample, the field device of interest is device FD3 located at wirelessnode 22. The wireless message according to the wireless protocolincludes the wireless node address, which is used to route the wirelessmessage through network 16. The field device address is contained in theHART message embedded within the wireless message, and is not used forrouting the wireless message through network 16. Instead, the fielddevice address is used once the wireless message has reached theintended node.

Mesh manager 62 causes radio 64 to transmit the wireless message, SOthat it will be transmitted by one or multiple hops within network 16 tonode 22. For example, the message to node 22 may be transmitted fromgateway 18 to node 20 and then to node 22, or alternatively from gateway18 to node 26 and then to node 22. Other routes are also possible innetwork 16.

Gateway interface 60 and mesh manager 62 also interact with hostcomputer 12 to manage the delivery of control messages to field devicesas if wireless network 16 were powered on even though it may be poweredoff (i.e. sleep mode). Mesh manager 60 determines the correct poweredstate of wireless network 16. It also calculates the time of the powercycles in order to determine the future time when wireless network 16will change state from power on to off, or from power off to on.Response time can be affected if a message is sent while power is on tothe wireless network, but a response will not occur until the next poweron cycle. Still another factor is the start-up time of the field device.Mesh manager 62 or gateway interface 60 may maintain a data base withstart-up times for the various field devices. By knowing field deviceaddress, an expected start-up time can be determined.

Based upon the current power state of wireless network 16, the amount oftime before wireless network will change state, the field device'sstart-up time, expected network message routing time, and the potentialfor a response to occur in the next power on cycle rather than thecurrent cycle, estimated times required for the message to be deliveredto the field device and for the response message to return to gateway 18can be calculated. That information can then be provided to hostcomputer 12. Since host computer 12 will not expect a response prior tothe estimated response time, the failure to receive a message prior tothat time will not be treated by host computer 12 as a communicationfailure or field device failure.

Based upon the factors affecting response time, gateway 18 may alsodetermine the best strategy to attempt communication with the fielddevice given the known power cycle of wireless network 16. For example,if a power cycle is about to change from on to off, a better strategymay be to wait until the beginning of the next power on cycle to beginrouting the message through wireless network 16.

As shown in FIG. 2, wireless node 22 includes radio 36, wireless devicerouter (WDR) 38, and field device FD3. In this particular example, fielddevice FD3 is a standard HART field device, which communicates fielddata using the HART control message protocol. Field device FD3 ispowered on and off by, and communicates directly with, WDR 38.

The wireless message transmitted over network 16 is received at radio 36of wireless node 22. The wireless message is checked by WDR 38 to seewhether it is addressed to node 22. Since node 22 is the destinationaddress, the wireless message is opened, and the embedded HART messageis extracted. WDR 38 determines that the HART message is intended forfield device FD3 based uon the field device address contained in theembedded HART message.

For power saving reasons, WDR 38 may be maintaining field device FD3 insleep mode until some action is required. Upon receiving the HARTmessage contained within the wireless message, WDR 38 takes steps tostart up field device FD3. This may be a matter of only a few seconds,or may be, for example, a delay on the order of 30 to 60 seconds. Whenfield device FD3 is ready to receive the HART message and act upon it,WDR 38 transmits the HART control message to field device FD3.

The message received by field device FD3 may require providing a messagein response that includes measurement data or other status information.Field device FD3 takes the necessary action to gather the measurementdata or generate the status information, generates a response message inthe HART control format, and transmits the message to WDR 38. The HARTresponse message is then modified and embedded into a wireless responsemessage according to the wireless protocol, and addressed to gateway 18.WDR 38 provides the wireless response message to radio 36 fortransmission onto wireless network 16. The wireless response message isthen transmitted in one or multiple hops to gateway 18, where the HARTresponse message is extracted from the wireless response message, isformatted in XML, and is transmitted over highspeed network 14 to hostcomputer 12.

FIG. 3 shows a diagram of a typical wireless message sent over thewireless network shown in FIGS. 1 and 2. Wireless message 70 includeswireless protocol bits 72, payload 74, and wireless protocol bits 76.Protocol bits 72 and 76 are required for proper routing of wirelessmessage 70 through mesh network 16 to the desired destination. Payload74 represents the substance of the control message being transmitted. Inthe present invention, the control message (in the control messageprotocol used by both host computer 12 and field devices FD1-FD9) isembedded within wireless message 70 as payload 74.

FIG. 4 shows the format of control message 80 as generated by hostcomputer 12. In this particular example, control message 80 isconfigured using the HART protocol. Control message 80 includes preamble82, delimiter 84, field device address 86, command 88, byte count 90,data 92, and check byte 94. Control message 80 is modified at gatewayinterface 60 and then embedded into wireless message 70 as payload 74.

FIG. 5 shows a first embodiment of the format of payload 74 formed fromcontrol message 80. To produce payload 74, interface 60 removes physicallayer overhead from control message 80 and adds sequence information.

As shown by a comparison of FIGS. 4 and 5, the first difference betweenpayload 74 and control message 80 is that preamble 82 has been removed.Since the control message will be sent over the network using thewireless protocol, the use of a preamble is unnecessary. Removal ofpreamble 82 improves efficiency of network 16 by eliminating unnecessaryinformation.

The second difference between payload 74 and control message 80 is theaddition of message ID 96, which is a two-byte number that follows data92, and precedes check byte 94. The removal of preamble 82 and theaddition of message ID 96 also requires that check byte 94 berecalculated.

The purpose of message ID 96 is for stale message rejection. This allowsthe receiver of a message to reject out of order messages. Wireless meshnetwork 16 is designed such that messages can take multiple paths to getto their destination. The message is passed from one node to another,and it is possible that the message may be delayed at a particular node.This could be caused by interference or poor signal quality. If amessage is delayed long enough, host 12 may issue a retry and/or a newmessage. In that case, it is possible that one or more messages mayarrive at the destination node before the delayed message is delivered.When the delayed control message is delivered, message ID 96 can be usedto accept or reject the control message.

FIG. 6 shows a second embodiment of the format of payload 74, in whichtrailer function code 98 and trailer payload (or message ID) 96 formtrailer frame 100, which is appended to the control message formed bydelimiter 84, field device address 86, command 88, byte count 90, data92 and check byte 94. Trailer 100 is not included in check byte 94, andinstead depends on the wireless network protocol layers for dataintegrity and reliability.

Trailer 100 contains function code 98 and payload 96 (which includes themessage ID, if any). Function code 98 is an unsigned byte which definesthe content of trailer 100. Undefined payload bytes such as additionalpadding bytes will be ignored. Use of trailer 100 only applies tomessages between gateway 18 and wireless field devices FD1-FD9. Table 1shows an example of function codes defined for trailer 100:

TABLE 1 Function Code Meaning Payload Length and Description 0 NoMessage ID 0-2 bytes (optional padding) 1 Force Accept 2 bytes - messageID 2 Clear Force Accept 2 bytes - message ID With Force 3 Normal MessageID 2 bytes - message ID

Function codes 0-3 are used with reference to a message ID. Message IDsare used for stale message rejection on wireless mesh network 16. Thisallows the receiver of a message to reject out of order messages.Additionally, message IDs can be used by gateway 18 to determine whetherpublished data has arrived out of order.

Rules for generating the Message ID are as follows:

The message ID enumerates a message sequence from a sender to areceiver. It is a two byte unsigned value which must be unique andincreasing by one with each new message ID.

A new message ID should be generated for every request/responsetransaction. Retries of a request from a sender to a receiver may re-usea message ID provided that there is no more than one request outstandingfrom a sender to a receiver. After receiving a valid request messagewith a valid message ID, the field device must echo back the receivedmessage ID with the response.

A new message ID should be generated for every publish message from adevice. Publish message IDs are generated independently ofrequest/response message IDs.

Rules for validating the Message ID are as follows:

The receiver must implement a window for validating message IDs SO thatthe validity comparison survives a rollover of the message ID counter.As an example, any messages within a window of 256 previous IDs could beignored as out of order by the WDR/field device. But, if message ID issafely outside the window the receiver should accept the message. Anyaccepted message will cause the message ID to be cached as the lastvalid received message ID.

After a restart, a receiver may accept the first message ID it receivesor else it must initialize its validity-checking in whatever manner thedevice application sees fit. A guideline for this initialization wouldbe for a device to always accept new stateless requests withoutrequiring a device publish to first reach the gateway.

The receiver of a published message with an invalid (out of order) IDmay either use or reject the message, depending on the receiver'sapplication.

Rules for interpreting function codes are as follows:

A sender can send a message without a message ID by either omittingtrailer 100 or by specifying NO MESSAGE ID as the function code. If aresponse is generated and the WDR/field device supports trailers, thereturn function code should be set to “NO MESSAGE ID”.

If a message ID is provided, it must be accepted if the function code isset to FORCE ACCEPT or CLEAR FORCE ACCEPT WITH FORCE. A message with afunction code of NORMAL ID will be subject to potential discard via themessage ID validation rules.

If gateway 18 has reset, it should make its first request using theFORCE ACCEPT function code. The will force the receiving field device toaccept the request and the attached message ID. This relieves gateway 18of needing to learn the value of the device's valid message ID counter.Gateway 18 should stop using FORCE ACCEPT once it has received a validresponse message with the matching message ID.

Gateway 18 should honor the CLEAR FORCE ACCEPT WITH FORCE function codeas a valid message ID, but a WDR/field device should not send CLEARFORCE ACCEPT WITH FORCE to gateway 18.

If a WDR/field device in the system has reset, it should send publishmessages with the command set to FORCE ACCEPT. This will force gateway18 to accept the published data.

If gateway 18 sees the FORCE ACCEPT function code, it may issue a CLEARFORCE ACCEPT WITH FORCE in a subsequent message along with a validmessage ID.

On receipt of CLEAR FORCE ACCEPT WITH FORCE, the WDR/field device shouldclear the force accept condition and always accept the message IDprovided.

The use of embedded control messages (in a control message protocol)within wireless messages (in a wireless protocol) enables the hostcomputer of a distributed control system to interact with field devicesthrough a wireless communication network. Control messages can beexchanged between the host computer and the field devices using knowncontrol message formats, such as HART, Fieldbus, or the like, withouthaving to be modified by either the host computer or the field devicesto accommodate transmission of the control messages over the wirelessnetwork. The control message is embedded within the wirelesscommunication protocol such that the substance of the control messageexchanged between the host computer and the field device is unmodifiedas a result of having passed through the wireless network.

Control messages that are too large to be routed through the wirelesscommunication protocol can be broken into parts and sent as multipleparts. Each part is embedded in a wireless message, and the multipleparts can be reassembled into the original control message as themultiple parts exit the wireless network. By use of a message ID in theembedded control message, the multiple parts can be reassembled inproper order, even though individual wireless messages having embeddedparts of the original control message may take different paths throughthe wireless network.

The translation of field device addresses to corresponding wirelessaddresses allows host 12 to function in its native field device addressdomain, while interacting with field devices within the wireless addressdomain. The use of wireless network 16 to route messages to and from thefield devices is transparent to host 12. The address translation andinclusion of both the wireless address and the field device address inthe wireless message allows multiple field devices associated with asingle node (i.e. a single wireless address) to be addressedindividually.

Although embedding the field device address in the payload of thewireless message as part of the control message is simple and effective,the field device address could be contained separately in the payload orelsewhere in the wireless message, if desired.

The presence of wireless network 16 is also made transparent to hostcomputer 12 by decoupling the transmission of messages to field devicesbetween host computer 12 and wireless network 16. Gateway 18 monitorsthe state of wireless network 16, and factors that can affect theresponse time to a message. By providing an estimated response time tomessages being sent by host computer 12, gateway 18 allows host computer12 to treat what field devices FD1-FD9 and wireless network 16 as ifthey were available on demand, even though network 16 and field devicesFD1-FD9 are often in a low power sleep state.

Although the present invention has been described with reference topreferred embodiments, workers skilled in the art will recognize thatchanges may be made in form and detail without departing from the spiritand scope of the invention. For example, control system 10 isillustrated with six nodes and nine field devices, but otherconfigurations with fewer or greater numbers of nodes and field devicesare equally applicable.

1. An industrial process control system comprising: a host; a fielddevice; and a wireless mesh network for routing wireless messagesbetween the host and the field device, the wireless messages includingmessage sequence information and a function code wherein a receiver of amessage detects stale messages based on the message sequence informationand rejects the stale messages unless message sequence based acceptancerules are overridden by the function code that forces acceptance of thedetected stale message.
 2. The system of claim 1, wherein the messagesequence information is embedded as a payload of a wireless message. 3.The system of claim 1, wherein the message sequence information includesa message ID number.
 4. The system of claim 3 , wherein the functioncode and the message ID number are embedded as a payload of a wirelessmessage.
 5. An industrial process control system comprising: a pluralityof field devices; a host for sending control messages to field devicesand receiving response messages from the field devices; and a wirelessnetwork routing wireless messages among a plurality of nodes, each nodeincluding at least one of the plurality of field devices, wherein thewireless messages include content of a control message or responsemessage, message sequence information relating to the control message orresponse message, and a function code for overriding message sequenceinformation based acceptance rules to force acceptance of a message,wherein a receiver of a message determines whether to accept the messagebased, in part, on the message sequence information and the functioncode.
 6. The system of claim 5, wherein the message sequence informationis embedded in the wireless message.
 7. The system of claim 6, whereinthe message sequence information includes a message ID number.
 8. Amethod of sending messages from a host to field devices of an industrialprocess control system over a wireless network having a plurality ofnodes, the method comprising: sending a control message addressed to afield device address from the host to the wireless network; sending awireless message containing content of the control message, messagesequence information, and a function code through the network to thenode having the corresponding wireless address; and delivering thecontent of the control message to the field device if the messagesequence information indicates that the control message is received inan acceptable order or the function code forces acceptance of thecontrol message despite the message sequence information.
 9. The methodof claim 8, wherein the wireless message includes the message sequenceinformation in a payload.
 10. The method of claim 8 and furthercomprising: opening the wireless message; extracting the messagesequence information from the wireless message; and determining whetherto accept the content of the control message based on the messagesequence information.
 11. The method of claim 8, wherein the messagesequence information includes a message ID number.
 12. A method ofsending messages between a host and a selected field device of anindustrial process control system over a wireless mesh network having aplurality of nodes, the method comprising: generating at the host acontrol message to the selected field device; sending the controlmessage to the wireless network; sending a wireless message containingcontent of the control message, message sequence information, and afunction code through the wireless network; receiving the wirelessmessage at a node associated with the selected field device; anddetermining whether to deliver the content of the control message to theselected field device based upon the message sequence information and ameaning of the function code, wherein a force accept function codecauses the content of the control message to be delivered despite themessage sequence information.
 13. The method of claim 12, wherein themessage sequence information includes a message ID number.
 14. Themethod of claim 13, wherein determining whether to deliver the contentcomprises: opening the wireless message at the node; extracting themessage sequence information from the wireless message; and determiningwhether the message ID number is in an acceptable order with respect toa previously received message ID number.
 15. The method of claim 12 andfurther comprising: generating a response by the selected field deviceto the control message; and sending the wireless message containing theresponse and the message ID number associated with the control messagethrough the network.
 16. The method of claim 15 and further comprising:delivering the response from the wireless mesh network to the host.